package flc.ast.adapter;

import android.widget.ImageView;

import androidx.annotation.NonNull;

import com.bumptech.glide.Glide;
import com.chad.library.adapter.base.provider.BaseItemProvider;
import com.chad.library.adapter.base.viewholder.BaseViewHolder;

import flc.ast.R;
import flc.ast.bean.DrawTempBean;
import stark.common.basic.adaptermutil.StkProviderMultiAdapter;
import stark.common.basic.adaptermutil.StkSingleSpanProvider;
import stark.common.bean.StkResBean;

public class DrawTempAdapter extends StkProviderMultiAdapter<DrawTempBean> {

    public DrawTempAdapter() {
        addItemProvider(new StkSingleSpanProvider(126));
        addItemProvider(new DrawTempProvider());
    }

    private class DrawTempProvider extends BaseItemProvider<DrawTempBean> {
        @Override
        public int getItemViewType() {
            return StkProviderMultiAdapter.TYPE_VIEW;
        }

        @Override
        public int getLayoutId() {
            return R.layout.item_draw_temp;
        }

        @Override
        public void convert(@NonNull BaseViewHolder baseViewHolder, DrawTempBean bean) {
            baseViewHolder.setImageResource(R.id.ivDrawTempItemImg, bean.getImg());
        }
    }

}
